<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.10"/>
<title>sock: sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">sock
   &#160;<span id="projectnumber">v0.11</span>
   </div>
   <div id="projectbrief">C++ Network Library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.10 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="namespacesock.html">sock</a></li><li class="navelem"><a class="el" href="namespacesock_1_1base.html">base</a></li><li class="navelem"><a class="el" href="classsock_1_1base_1_1_locked_queue.html">LockedQueue</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classsock_1_1base_1_1_locked_queue-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt; Class Template Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p><code>#include &lt;<a class="el" href="queue_8h_source.html">queue.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt;:</div>
<div class="dyncontent">
 <div class="center">
  <img src="classsock_1_1base_1_1_locked_queue.png" usemap="#sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt;_map" alt=""/>
  <map id="sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt;_map" name="sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt;_map">
</map>
 </div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a71ae9dfe7fc5553937635ee378b3295e"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#a71ae9dfe7fc5553937635ee378b3295e">LockedQueue</a> ()</td></tr>
<tr class="separator:a71ae9dfe7fc5553937635ee378b3295e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9c2c2db4e4c677067ce47df315087292"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#a9c2c2db4e4c677067ce47df315087292">LockedQueue</a> (size_t size)</td></tr>
<tr class="separator:a9c2c2db4e4c677067ce47df315087292"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad43055dcb476f56dcca32f573c2f810a"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#ad43055dcb476f56dcca32f573c2f810a">~LockedQueue</a> ()</td></tr>
<tr class="separator:ad43055dcb476f56dcca32f573c2f810a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3a957e01a4e18b2c2ca7b459eb11f5f6"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#a3a957e01a4e18b2c2ca7b459eb11f5f6">pop_front</a> (T &amp;x)</td></tr>
<tr class="separator:a3a957e01a4e18b2c2ca7b459eb11f5f6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae2ebf044359e2fbc751f584295a8cb5d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#ae2ebf044359e2fbc751f584295a8cb5d">pop_front</a> ()</td></tr>
<tr class="separator:ae2ebf044359e2fbc751f584295a8cb5d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a27e5f8e6ab8642a31359b4355fc9d318"><td class="memItemLeft" align="right" valign="top">T &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#a27e5f8e6ab8642a31359b4355fc9d318">front</a> (void)</td></tr>
<tr class="separator:a27e5f8e6ab8642a31359b4355fc9d318"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa71a79935d2b6c1fa2d4e9d0f3335196"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#aa71a79935d2b6c1fa2d4e9d0f3335196">push_back</a> (const T &amp;x)</td></tr>
<tr class="separator:aa71a79935d2b6c1fa2d4e9d0f3335196"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac0d09919fcac2c25e990dae18253b268"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#ac0d09919fcac2c25e990dae18253b268">empty</a> (void)</td></tr>
<tr class="separator:ac0d09919fcac2c25e990dae18253b268"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5cafaa0c6d0705a5847bab58be8bb393"><td class="memTemplParams" colspan="2">template&lt;class Checker &gt; </td></tr>
<tr class="memitem:a5cafaa0c6d0705a5847bab58be8bb393"><td class="memTemplItemLeft" align="right" valign="top">bool&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classsock_1_1base_1_1_locked_queue.html#a5cafaa0c6d0705a5847bab58be8bb393">next</a> (T &amp;x, Checker &amp;checker)</td></tr>
<tr class="memdesc:a5cafaa0c6d0705a5847bab58be8bb393"><td class="mdescLeft">&#160;</td><td class="mdescRight">从队列中取下一个通过Checker检查的元素  <a href="#a5cafaa0c6d0705a5847bab58be8bb393">More...</a><br /></td></tr>
<tr class="separator:a5cafaa0c6d0705a5847bab58be8bb393"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt;<br />
class sock::base::LockedQueue&lt; T, LOCK, STORAGE &gt;</h3>

<p>加锁队列 </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a71ae9dfe7fc5553937635ee378b3295e"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::<a class="el" href="classsock_1_1base_1_1_locked_queue.html">LockedQueue</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a9c2c2db4e4c677067ce47df315087292"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::<a class="el" href="classsock_1_1base_1_1_locked_queue.html">LockedQueue</a> </td>
          <td>(</td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>size</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="ad43055dcb476f56dcca32f573c2f810a"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::~<a class="el" href="classsock_1_1base_1_1_locked_queue.html">LockedQueue</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="ac0d09919fcac2c25e990dae18253b268"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::empty </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a27e5f8e6ab8642a31359b4355fc9d318"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">T&amp; <a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::front </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="a5cafaa0c6d0705a5847bab58be8bb393"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<div class="memtemplate">
template&lt;class Checker &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::next </td>
          <td>(</td>
          <td class="paramtype">T &amp;&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">Checker &amp;&#160;</td>
          <td class="paramname"><em>checker</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>从队列中取下一个通过Checker检查的元素 </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">x</td><td>用来返回 </td></tr>
    <tr><td class="paramname">checker</td><td>检查器，检查器需要有(bool process(T&amp;))函数 </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a3a957e01a4e18b2c2ca7b459eb11f5f6"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::pop_front </td>
          <td>(</td>
          <td class="paramtype">T &amp;&#160;</td>
          <td class="paramname"><em>x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="ae2ebf044359e2fbc751f584295a8cb5d"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::pop_front </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<a class="anchor" id="aa71a79935d2b6c1fa2d4e9d0f3335196"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T, typename LOCK, typename STORAGE = std::deque&lt;T&gt;&gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="classsock_1_1base_1_1_locked_queue.html">sock::base::LockedQueue</a>&lt; T, LOCK, STORAGE &gt;::push_back </td>
          <td>(</td>
          <td class="paramtype">const T &amp;&#160;</td>
          <td class="paramname"><em>x</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>E:/git/sock/sock/base/<a class="el" href="queue_8h_source.html">queue.h</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.10
</small></address>
</body>
</html>
